sympy2c: From symbolic expressions to fast C/C++ functions and ODE solvers in Python
نویسندگان
چکیده
Computer algebra systems play an important role in science as they facilitate the development of new theoretical models. The resulting symbolic equations are often implemented a compiled programming language order to provide fast and portable codes for practical applications. We describe sympy2c, Python package designed bridge gap between numerical implementation model. sympy2c translates SymPy C/C++ code that is optimized using transformations. functions can be conveniently used extension module Python. within PyCosmo solve Einstein–Boltzmann equations, large system ODEs describing evolution linear perturbations Universe. After reviewing functionalities usage we its optimization strategies. This includes, particular, novel approach generate ODE solvers making use sparsity Jacobian matrix. demonstrate performance test case. general potentially useful various areas computational physics. publicly available at https://cosmology.ethz.ch/research/software-lab/sympy2c.html.
منابع مشابه
COPADS IV: Fixed Time-Step ODE Solvers for a System of Equations Implemented as a Set of Python Functions
Ordinary differential equation (ODE) systems are commonly used many different fields. The de-facto method to implement an ODE system in Python programming using SciPy requires the entire system to be implemented as a single function, which only allow for inline documentation. Although each equation can be broken up into sub-equations, there is no compart-mentalization of sub-equations to its OD...
متن کاملthe role of russia in transmission of energy from central asia and caucuses to european union
پس ازفروپاشی شوروی،رشد منابع نفت و گاز، آسیای میانه و قفقاز را در یک بازی ژئوپلتیکی انرژی قرار داده است. با در نظر گرفتن این منابع هیدروکربنی، این منطقه به یک میدانجنگ و رقابت تجاری برای بازی های ژئوپلتیکی قدرت های بزرگ جهانی تبدیل شده است. روسیه منطقه را به عنوان حیات خلوت خود تلقی نموده و علاقمند به حفظ حضورش می باشد تا همانند گذشته گاز طبیعی را به وسیله خط لوله مرکزی دریافت و به عنوان یک واس...
15 صفحه اولepidemiological study of oral and pharyngeal cancers in kermanshah province from march 1993 to march 2006
چکیده ندارد.
15 صفحه اولSimple ODE Solvers - Error Behaviour
y(t0) = y0 Here f(t, y) is a given function, t0 is a given initial time and y0 is a given initial value for y. The unknown in the problem is the function y(t). Two obvious considerations in deciding whether or not a given algorithm is of any practical value are (a) the amount of computational effort required to execute the algorithm and (b) the accuracy that this computational effort yields. Fo...
متن کاملSimple ODE Solvers - Error Behaviour
y(t0) = y0 Here f(t, y) is a given function, t0 is a given initial time and y0 is a given initial value for y. The unknown in the problem is the function y(t). Two obvious considerations in deciding whether or not a given algorithm is of any practical value are (a) the amount of computational effort required to execute the algorithm and (b) the accuracy that this computational effort yields. Fo...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
ژورنال
عنوان ژورنال: Astronomy and Computing
سال: 2023
ISSN: ['2213-1345', '2213-1337']
DOI: https://doi.org/10.1016/j.ascom.2022.100666